#pragma once
#ifndef __AUDIO_PLAY_H
#define __AUDIO_PLAY_H

#include <QAudioFormat>
#include <QAudioOutput>

#include <thread>
#include <chrono>

#include "audio_ctrl.h"

class AudioPlayThread : public QThread
{
	Q_OBJECT

public:
	explicit AudioPlayThread(int id = 0, QObject* parent = nullptr) : m_id(id),
		QThread(parent),
		m_audio_play_stop(false)
	{
	}

	void audio_play_start();
	void audio_play_stop();

protected:
	void run() override;

private:
	int m_id;
	bool m_audio_play_stop;


};


#endif // !__AUDIO_PLAY_H
